package com.aaa.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * 
 * @TableName mbs_member
 */
@ApiModel(description = "会员")
@TableName(value ="mbs_member")
@Data
public class Member implements Serializable {
    /**
     * 会员客户ID
     */
    @ApiModelProperty("会员客户ID")
    @TableId(type = IdType.AUTO)
    private Integer id;

    /**
     * 账号
     */
    @ApiModelProperty("账号")
    private String username;

    /**
     * 密码
     */
    @ApiModelProperty("密码")
    private String password;

    /**
     * 盐值列
     */
    @ApiModelProperty("盐值列")
    private String pwSalt;

    /**
     * 账号状态（帐号启用状态:0->启用；1->禁用）
     */
    @ApiModelProperty("账号状态（帐号启用状态:0->启用；1->禁用）")
    private Integer status;

    /**
     * (身份证，护照，军官证，台胞证，港澳台来往内地通行证)
     */
    @ApiModelProperty("(身份证，护照，军官证，台胞证，港澳台来往内地通行证)")
    private String idType;

    /**
     * 正面
     */
    @ApiModelProperty("正面")
    private String pathFront;

    /**
     * 反面
     */
    @ApiModelProperty("反面")
    private String pathReverse;

    /**
     * 客户名字
     */
    @ApiModelProperty("客户名字")
    private String name;

    /**
     * 联系人
     */
    @ApiModelProperty("联系人")
    private String contactName;

    /**
     * 联系电话
     */
    @ApiModelProperty("联系电话")
    private String contactPhone;

    /**
     * 联系地址
     */
    @ApiModelProperty("联系地址")
    private String contactAddress;

    /**
     * 驾照号
     */
    @ApiModelProperty("驾照号")
    private String licenseNo;

    /**
     * 性别
     */
    @ApiModelProperty("性别")
    private String sex;

    /**
     * 电话
     */
    @ApiModelProperty("电话")
    private String phoneNum;

    /**
     * 地址
     */
    @ApiModelProperty("地址")
    private String address;

    /**
     * 邮箱
     */
    @ApiModelProperty("邮箱")
    private String email;

    /**
     * 会员级别（普通，金卡，白金，钻石）
     */
    @ApiModelProperty("会员级别（普通，金卡，白金，钻石）")
    private Integer memberLevelId;

    /**
     * 账户余额
     */
    @ApiModelProperty("账户余额")
    private Double accountBalance;

    /**
     * 积分
     */
    @ApiModelProperty("积分")
    private Integer integration;

    /**
     * 成长值
     */
    @ApiModelProperty("成长值")
    private Double growth;

    /**
     * 历史积分数量(只加不减)
     */
    @ApiModelProperty("历史积分数量(只加不减)")
    private String historyIntegration;

    /**
     * 微信返回ID
     */
    @ApiModelProperty("微信返回ID")
    private Integer openId;

    /**
     * 登录验证token
     */
    @ApiModelProperty("登录验证token")
    private String token;

    /**
     * 证件编号
     */
    @ApiModelProperty("证件编号")
    private String idCard;

    @ApiModelProperty(hidden = true)
    @TableField(exist = false)
    private String code;

    /**
     * 头像
     */
    @ApiModelProperty("头像")
    @TableField(exist = false)
    private String memberLevel;


    @ApiModelProperty(hidden = true)
    private String headPic;

    @ApiModelProperty(hidden = true)
    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        Member other = (Member) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getUsername() == null ? other.getUsername() == null : this.getUsername().equals(other.getUsername()))
            && (this.getPassword() == null ? other.getPassword() == null : this.getPassword().equals(other.getPassword()))
            && (this.getPwSalt() == null ? other.getPwSalt() == null : this.getPwSalt().equals(other.getPwSalt()))
            && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
            && (this.getIdType() == null ? other.getIdType() == null : this.getIdType().equals(other.getIdType()))
            && (this.getPathFront() == null ? other.getPathFront() == null : this.getPathFront().equals(other.getPathFront()))
            && (this.getPathReverse() == null ? other.getPathReverse() == null : this.getPathReverse().equals(other.getPathReverse()))
            && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
            && (this.getContactName() == null ? other.getContactName() == null : this.getContactName().equals(other.getContactName()))
            && (this.getContactPhone() == null ? other.getContactPhone() == null : this.getContactPhone().equals(other.getContactPhone()))
            && (this.getContactAddress() == null ? other.getContactAddress() == null : this.getContactAddress().equals(other.getContactAddress()))
            && (this.getLicenseNo() == null ? other.getLicenseNo() == null : this.getLicenseNo().equals(other.getLicenseNo()))
            && (this.getSex() == null ? other.getSex() == null : this.getSex().equals(other.getSex()))
            && (this.getPhoneNum() == null ? other.getPhoneNum() == null : this.getPhoneNum().equals(other.getPhoneNum()))
            && (this.getAddress() == null ? other.getAddress() == null : this.getAddress().equals(other.getAddress()))
            && (this.getEmail() == null ? other.getEmail() == null : this.getEmail().equals(other.getEmail()))
            && (this.getMemberLevelId() == null ? other.getMemberLevelId() == null : this.getMemberLevelId().equals(other.getMemberLevelId()))
            && (this.getAccountBalance() == null ? other.getAccountBalance() == null : this.getAccountBalance().equals(other.getAccountBalance()))
            && (this.getIntegration() == null ? other.getIntegration() == null : this.getIntegration().equals(other.getIntegration()))
            && (this.getGrowth() == null ? other.getGrowth() == null : this.getGrowth().equals(other.getGrowth()))
            && (this.getHistoryIntegration() == null ? other.getHistoryIntegration() == null : this.getHistoryIntegration().equals(other.getHistoryIntegration()))
            && (this.getOpenId() == null ? other.getOpenId() == null : this.getOpenId().equals(other.getOpenId()))
            && (this.getToken() == null ? other.getToken() == null : this.getToken().equals(other.getToken()))
            && (this.getIdCard() == null ? other.getIdCard() == null : this.getIdCard().equals(other.getIdCard()))
            && (this.getHeadPic() == null ? other.getHeadPic() == null : this.getHeadPic().equals(other.getHeadPic()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getUsername() == null) ? 0 : getUsername().hashCode());
        result = prime * result + ((getPassword() == null) ? 0 : getPassword().hashCode());
        result = prime * result + ((getPwSalt() == null) ? 0 : getPwSalt().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getIdType() == null) ? 0 : getIdType().hashCode());
        result = prime * result + ((getPathFront() == null) ? 0 : getPathFront().hashCode());
        result = prime * result + ((getPathReverse() == null) ? 0 : getPathReverse().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getContactName() == null) ? 0 : getContactName().hashCode());
        result = prime * result + ((getContactPhone() == null) ? 0 : getContactPhone().hashCode());
        result = prime * result + ((getContactAddress() == null) ? 0 : getContactAddress().hashCode());
        result = prime * result + ((getLicenseNo() == null) ? 0 : getLicenseNo().hashCode());
        result = prime * result + ((getSex() == null) ? 0 : getSex().hashCode());
        result = prime * result + ((getPhoneNum() == null) ? 0 : getPhoneNum().hashCode());
        result = prime * result + ((getAddress() == null) ? 0 : getAddress().hashCode());
        result = prime * result + ((getEmail() == null) ? 0 : getEmail().hashCode());
        result = prime * result + ((getMemberLevelId() == null) ? 0 : getMemberLevelId().hashCode());
        result = prime * result + ((getAccountBalance() == null) ? 0 : getAccountBalance().hashCode());
        result = prime * result + ((getIntegration() == null) ? 0 : getIntegration().hashCode());
        result = prime * result + ((getGrowth() == null) ? 0 : getGrowth().hashCode());
        result = prime * result + ((getHistoryIntegration() == null) ? 0 : getHistoryIntegration().hashCode());
        result = prime * result + ((getOpenId() == null) ? 0 : getOpenId().hashCode());
        result = prime * result + ((getToken() == null) ? 0 : getToken().hashCode());
        result = prime * result + ((getIdCard() == null) ? 0 : getIdCard().hashCode());
        result = prime * result + ((getHeadPic() == null) ? 0 : getHeadPic().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", username=").append(username);
        sb.append(", password=").append(password);
        sb.append(", pwSalt=").append(pwSalt);
        sb.append(", status=").append(status);
        sb.append(", idType=").append(idType);
        sb.append(", pathFront=").append(pathFront);
        sb.append(", pathReverse=").append(pathReverse);
        sb.append(", name=").append(name);
        sb.append(", contactName=").append(contactName);
        sb.append(", contactPhone=").append(contactPhone);
        sb.append(", contactAddress=").append(contactAddress);
        sb.append(", licenseNo=").append(licenseNo);
        sb.append(", sex=").append(sex);
        sb.append(", phoneNum=").append(phoneNum);
        sb.append(", address=").append(address);
        sb.append(", email=").append(email);
        sb.append(", memberLevelId=").append(memberLevelId);
        sb.append(", accountBalance=").append(accountBalance);
        sb.append(", integration=").append(integration);
        sb.append(", growth=").append(growth);
        sb.append(", historyIntegration=").append(historyIntegration);
        sb.append(", openId=").append(openId);
        sb.append(", token=").append(token);
        sb.append(", idCard=").append(idCard);
        sb.append(", headPic=").append(headPic);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}